package com.erlinyou.im.model.goodfirend;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.IdClass;
import javax.persistence.Table;

import com.erlinyou.im.model.base.AbstractDO;

@Entity
@Table(name="tchat_goodfirend")
@IdClass(GoodfirendKey.class)
public class Goodfirend extends AbstractDO{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	@Id
	private long userid;
	@Id
	private long jid;
	
	private int relation;
	
	private long createtime;
	
	private int noreadnum;
	
	private String permission;
	private String fpermission;
	

	
	
	public String getPermission() {
		return permission;
	}

	public void setPermission(String permission) {
		this.permission = permission;
	}

	public long getUserid() {
		return userid;
	}

	public void setUserid(long userid) {
		this.userid = userid;
	}

	public long getJid() {
		return jid;
	}

	public void setJid(long jid) {
		this.jid = jid;
	}

	public int getRelation() {
		return relation;
	}

	public void setRelation(int relation) {
		this.relation = relation;
	}

	public long getCreatetime() {
		return createtime;
	}

	public void setCreatetime(long createtime) {
		this.createtime = createtime;
	}

	
	
	public Goodfirend copy() {
		return new Goodfirend(userid,jid,relation,createtime);
	}

	public Goodfirend() {
		super();
	}

	public Goodfirend(long userid, long jid, int relation, long createtime) {
		super();
		this.userid = userid;
		this.jid = jid;
		this.relation = relation;
		this.createtime = createtime;
	}

	public int getNoreadnum() {
		return noreadnum;
	}

	public void setNoreadnum(int noreadnum) {
		this.noreadnum = noreadnum;
	}

	public String getFpermission() {
		return fpermission;
	}

	public void setFpermission(String fpermission) {
		this.fpermission = fpermission;
	}

	
	
	
	
}
